<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<!DOCTYPE html>
<html>
<head>
    <title>注册</title>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <style>
        /* 样式表 */
        body {
            font-family: Arial, Helvetica, sans-serif;
            background-color: #f1f1f1;
        }

        /* 注册表单容器 */
        .register-container {
            background-color: #ffffff;
            padding: 20px;
            border-radius: 10px;
            box-shadow: 0px 0px 10px rgba(0, 0, 0, 0.2);
            max-width: 500px;
            margin: 0 auto;
        }

        /* 注册表单标题 */
        h1 {
            text-align: center;
            font-size: 36px;
            margin-bottom: 30px;
        }

        /* 输入框 */
        input[type=text], input[type=password] {
            width: 100%;
            padding: 12px 20px;
            margin: 8px 0;
            display: inline-block;
            border: 1px solid #ccc;
            border-radius: 4px;
            box-sizing: border-box;
        }

        /* 验证码输入框 */
        #verification_code {
            width: 50%;
            display: inline-block;
        }

        #verification_code ~ img{
            vertical-align: top;
        }

        /* 发送验证码按钮 */
        button[type=button] {
            background-color: #4CAF50;
            color: white;
            padding: 14px 20px;
            margin: 8px 0;
            border: none;
            border-radius: 4px;
            cursor: pointer;
            width: 40%;
        }

        /* 注册按钮 */
        button[type=submit] {
            background-color: #4CAF50;
            color: white;
            padding: 14px 20px;
            margin: 8px 0;
            border: none;
            border-radius: 4px;
            cursor: pointer;
            width: 100%;
        }

        /* 登录链接 */
        .login {
            text-align: center;
        }

        .login a {
            color: #2196F3;
        }

        /* 错误信息 */
        .error {
            color: #ff0000;
            text-align: center;
        }
    </style>
</head>

<body>
<div class="register-container">
    <h1>注册</h1>
    <p class="error">${msg}</p>
    <form action="register" method="post">
        <label for="phone">手机号</label>
        <input type="text" id="phone" name="phone" placeholder="请输入手机号">

        <label for="password">密码</label>
        <input type="password" id="password" name="password" placeholder="请输入密码">

        <label for="confirm_password">确认密码</label>
        <input type="password" id="confirm_password" name="confirm_password" placeholder="请确认密码">
        <label for="name">姓名</label>
        <input type="text" id="name" name="name" placeholder="请确认姓名">
        <label for="verification_code">验证码</label>
        <input type="text" id="verification_code" name="verification_code" placeholder="请输入验证码">
        <img id="img" src="captcha" alt="验证码" />

        <button type="submit">注册</button>
    </form>

    <div class="login">
        <a href="index.jsp">已有账户？登录</a>
    </div>
</div>
</body>
</html>

